{% extends "main/base.html" %}

{% block content %}

{% if form.errors %}
<p>Your email and password didn't match. Please try again.</p>
{% endif %}

<h1>OCMS Login</h1>

<form method="post" action="{% url django.contrib.auth.views.login %}">
{% csrf_token %}
<table>
<tr>
    <td>Email</td>
    <td>{{ form.username }}</td>
</tr>
<tr>
    <td>{{ form.password.label_tag }}</td>
    <td>{{ form.password }}</td>
</tr>
</table>

<input type="submit" value="Login" />
<input type="button" value="Reset Password" ONCLICK="window.location.href='{% url django.contrib.auth.views.password_reset %}'">
<input type="hidden" name="next" value="{{ next }}" />
</form>

{% endblock %}